package demo2;

/**
 * @Author liangzai
 * @Description:
 */
public class Rectangle {
    private double height = 1;
    private double weight = 1;

    public Rectangle() {
    }

    public Rectangle(double height, double weight) {
        this.height = height;
        this.weight = weight;
    }

    public double getArea(){
        return (this.height*this.weight);
    }

    public double getPerimeter(){
        return this.height*2+this.weight*2;
    }
}
